package business;

import java.util.ArrayList;
import java.util.Map;

import model.SubjectContent;
import model.Subtopics;
import model.beans.SubtopicBean;

public class Subtemas {
	public static ArrayList list(int  int_topicId, int int_unitNumber, String str_academy, String str_subject){				
		ArrayList arrL_list = Subtopics.list(int_topicId, int_unitNumber, str_academy, str_subject);		
		return arrL_list;
	}

	public static int edit(Map map_data){
		return Subtopics.edit(map_data);
	}
	
	public static SubtopicBean instance( int int_subtopicId ){
		return Subtopics.instance(int_subtopicId);
	}
	
	public static int add( Map map_data, int int_topicId){
		return Subtopics.add(map_data, int_topicId);
	}
	
	public static int delete( int int_subtopicId ){
		int int_retVal = 0;
		if( !SubjectContent.existsDates(int_subtopicId) ){
			int_retVal = Subtopics.delete(int_subtopicId);
		}
		return int_retVal;
	}
}
